/*
 * @Author: Leng
 * @Date: 2023-09-08 22:55:28
 * @Description: home数据类型定义
 * @FilePath: \uni-app-template\src\types\home.ts
 */
export namespace typeHome {
  // 列表数据
  interface interRecommendData {
    id: number
    img: string
    title: string
    avatar: string
    userName: string
    like: number
  }
  // 列表请求入参
  export interface paramsRecommend {
    cityId: string | number
    cityName?: string
    pageIndex: number
    pageCount: number
  }
  // 列表总数据
  export interface homeData {
    paramsRecommend: paramsRecommend,
    interRecommendData: interRecommendData[]
  }
  // 默认值
  export class IhomeData implements homeData {
    paramsRecommend: paramsRecommend = {
      cityId: 10801,
      cityName: "上海",
      pageIndex: 1,
      pageCount: 20,
    }
    interRecommendData: interRecommendData[] = [
      {
        id: 1,
        img: "https://cdn.uviewui.com/uview/album/7.jpg",
        title: "作者一定是个及其有趣的人，哇哇哇😄",
        avatar: "https://cdn.uviewui.com/uview/album/7.jpg",
        userName: "冷冷",
        like: 0
      }
    ]
  }
}